<!--<?php print <<<EOT
-->
<script type="text/javascript" language="JavaScript" src="js/pw_ajax.js"></script>
<div id="main">
	<div id="breadCrumb">
		<strong><a href="index.php?m=house">{$house_sitename}</a></strong>
<!--#
if ($houseinfo['area']) {
#-->
		>> <a href="{$houseBaseUrl}q=list&area={$houseinfo['area']}">{$house_field['area'][$houseinfo['area']]['name']}</a>
<!--#
}
#-->
		>> <a href="{$houseBaseUrl}q=info&hid={$hid}">{$houseinfo['name']}</a>
	</div>
	<div id="banner" class="mb" style="background:url({$houseinfo['banner']}) no-repeat 0 0;">
	<div id="house-title">
		<h1>{$houseinfo['name']}</h1>
		<span class="status">
<!--#
if ($houseinfo['status'] == 1) {
#-->
			<span class="new">新盘</span>
<!--#
} elseif ($houseinfo['status'] == 2) {
#-->
			<span class="onsale">在售</span>
<!--#
} elseif ($houseinfo['status'] == 3) {
#-->
			<span class="rest">尾盘</span>
<!--#
} else {
#-->
			<span class="sold-out">售空</span>
<!--#
}
#-->
		</span>
	</div>
	<ul id="main-nav">
			<li class="current"><a href="{$houseBaseUrl}q=info&hid=$hid">楼盘信息</a></li>
			<li><a href="{$houseBaseUrl}q=album&hid=$hid">相册</a></li>
<!--#
if ($houseinfo['cyid']) {
#-->
			<li><a href="thread.php?cyid={$houseinfo['cyid']}">业主小区</a></li>
<!--#
}
foreach ($houseinfo['nav'] as $key => $value) {
#-->
			<li><a href="{$value['link']}"{$value['a_style']}>{$value['title']}</a></li>
<!--#
}
#-->
		</ul>
		<div id="sub-nav">
			<b class="l"></b>
			<ul>
				<li><a href="$houseInfo#house-infos">基本信息</a></li>
				<li><a href="$houseInfo#house-detail">详细信息</a></li>
				<li><a href="$imageTypeUrl&typeid=1">户型图</a></li>
				<li><a href="$imageTypeUrl&typeid=2">样板间</a></li>
				<li><a href="$imageTypeUrl&typeid=3">实景图</a></li>
				<li><a href="$imageTypeUrl&typeid=4">规划图</a></li>
				<li><a href="{$houseBaseUrl}q=video&hid=$hid">视频</a></li>
				<li><a href="$houseInfo#e-map">地图</a></li>
				<li><a href="{$houseBaseUrl}q=pricedetail&hid=$hid">价格明细</a></li>
				<li><a href="$houseInfo#house-detail" onclick="tab_change(jQuery('#hosue-round'),jQuery('#house-detail').find('.tab-panel'));">周边配套</a></li>
				<li class="current"><a href="$houseScore">楼盘点评</a></li>
			</ul>
			<b class="r"></b>
		</div>
	</div>
<div class="cc mb">
		<div class="w-715 fl">
<!-- 评分 -->
<div class="pw-hbox mb" id="koubei">
	<div class="hd">
		<h3>$houseinfo[name]<em>楼盘口碑榜 </em></h3>
	</div>
	<div class="bd">
		<dl class="cc" id="overall">
			<dt>楼盘<br/>点评：</dt>
			<dd><b class="lt"></b><b class="lb"></b><b class="rt"></b><b class="rb"></b>
				<div class="overall-wrap"><div class="overall-con">$scoreinfo[total]</div></div></dd>
		</dl>
		<div class="cc" id="house-score">
			<div class="score-box" style="background:none">
				<h4>网友综合楼盘评分（{$count}人参加）：</h4>
				{$scorehtml}
			</div>
			<div class="score-box2 star-box" style="background:none">
				<h4>个人楼盘评分：</h4>
				<div class="star-list">
					{$starhtml}
				</div>
				<p class="my-score">该楼盘总分<br/><strong>{$totalScore}分</strong><br/><em>/{$fullScore}分</em></p>
			</div>
		</div>
	</div>
</div>

<!-- 评论 -->
<a name="p2"></a>
<div class="pw-hbox mb" id="comments">
	<div class="hd">
		<h3>$houseinfo[name]<em>网友点评</em></h3>
	</div>
	<div class="bd">
		<div class="cc" id="top-pages">
			<div class="pages">$evaluations[pages]&nbsp;</div>
			<a href="$baseurl&hid=$hid#p1" class="put-out">我要点评</a>
		</div>
		<ul class="comments-list">
<!--
EOT;
foreach($evaluations['contents'] as $value){
if ($value['ifcheck']) {
print <<<EOT
-->
			<li class="item">
				<a href="mode.php?m=o&q=user&username=$value[username]"><h4>$value[username]</h4></a>
<!--
EOT;
if($ifCommentManager){
print <<<EOT
-->
				<p class="options"><a class="del" onclick="deleteEvaluations('$baseurl&id=$value[id]&hid=$hid&step=evaldel#p2')" href="javascript:;">[删除评论]</a></p>
<!--
EOT;
}print <<<EOT
-->
				<div class="avatar"><a href="mode.php?m=o&q=user&username=$value[username]"><img src="$value[icon]" width="50" height="50"/></a></div>
				<div class="comment-con"><p>$value[content]</p></div>
			</li>
<!--
EOT;
}
}print <<<EOT
-->
		</ul>
		<div class="cc" id="top-pages">
			<div class="pages">$evaluations[pages]&nbsp;</div>
		</div>
		<a name="p1"></a>
		<form action="$baseurl&#p1" method="post" name="F" onsubmit="return sendPostEvaluations('$baseurl&#p1',document.F)">
			<input type="hidden" name="hid" value="$hid">
			<input type="hidden" name="step" value="evaledit"/>
			<p class="review"><em>点评：</em> <textarea name="content"></textarea> </p>
			<p class="review-btn"><button type="submit">提 交</button></p>
		</form>
	</div>
</div>
<script type="text/javascript">
function sendPostEvaluations(url,form){
	if(form.content.value == ''){
		showDialog('error','点评内容不能为空');
		return false;
	}
	ajax.send(url,form,function(){
		ajax.guide();
		form.content.value = '';
	});
	return false;
}
function deleteEvaluations(url){
	showDialog('confirm','您确认要删除此条评论吗？','',function(){
		ajax.send(url,'',ajax.guide);
	});
}
</script>
<!-- 评论end -->

		</div>
		<div class="w-235 fr">
			<div class="house-tools mb">
				<div class="hd">
					<h3>楼盘点评榜</h3>
					<!-- <a href="#" class="more">更多>></a> -->
				</div>
				<div class="bd">
					<ol class="pw-hlist house-list">
<!--#
$cache_scoreHouse = $pageCache->getData('scoreHouse');
foreach ($cache_scoreHouse as $key=> $value) { 
	$temp = $key + 1;
#-->
						<li><a href="$value[url]"><span class="house-name">{$temp}.{$value[name]}</span> <span>{$value[area]}</span> <span>{$value[aveprice]}</span> <span>{$value[state]}</span></a></li>
<!--# } #-->
					</ol>
				</div>
			</div>
			<div class="house-tools mb">
				<div class="hd">
					<h3>推荐楼盘</h3>
					<!-- <a href="#" class="more">更多>></a> -->
				</div>
				<div class="bd">
					<ol class="pw-hlist house-list">
<!--#
$cache_recommendHouse = $pageCache->getData('recommendHouse');
foreach ($cache_recommendHouse as $key=> $value) { 
	$temp = $key + 1;
#-->
						<li><a href="$value[url]"><span class="house-name">{$temp}.{$value[name]}</span> <span>{$value[area]}</span> <span>{$value[aveprice]}</span> <span>{$value[state]}</span></a></li>
<!--# } #-->
					</ol>
				</div>
			</div>
			<div style="border: 1px solid rgb(217, 217, 217); padding: 6px;">
				<div style="margin-bottom: 6px;"><a href="#"><img src="images/ad220x60.jpg"/></a></div>
				<div style="margin-bottom: 6px;"><a href="#"><img src="images/ad220x60.jpg"/></a></div>
				<div style="margin-bottom: 6px;"><a href="#"><img src="images/ad220x60.jpg"/></a></div>
				<div><a href="#"><img src="images/ad220x60.jpg"/></a></div>
			</div>
			
		</div>
	</div>
	<div class="mb"><a href="#"><img src="images/ad960.jpg"/></a></div>
</div>
<script type="text/javascript">
var starInfoObj = {};
var scoreCount = '$scoreCount';
var scorekeysArray = "$scoreKeys".split(',');
function setOnclickEvent(){
	try{
		for(var i = 0 ; i < scorekeysArray.length ; i++){
			for(var j = 1 ; j <= 5 ; j++){
				var obj = getObj('star_'+ j +'_'+ scorekeysArray[i]);
				if(obj != null){
					obj.onclick = clickStar;
				}else{
					var obj1 = getObj(scorekeysArray[i]+'_span');
					if(obj1 != null){
						obj1.onclick = clickStar2;
					}
				}
			}
		}
	}catch(e){
	}
}
function clickStar(){
	try{
		if('$groupid' == 'guest'){
			showDialog("warning","您还未登录，不能进行评分！",2);
			return false;
		}
		var startvalue = this.id.substr(5,1);
		var starttype = this.id.substr(7,1);
		var className = this.className;
		/*重置其他评分*/
		for(var i=1; i<=5; i++) {
			var obj = getObj('star_'+ i +'_'+ starttype);
			var cn = obj.className;
			if (cn.indexOf('-h') != -1) {
				obj.className = cn.replace('-h','');
			}
		}
		if (className.indexOf('-h') == -1) {
			this.className = this.className + '-h' ;
		}
		starInfoObj[starttype] = startvalue;
		var flag = true;
		for(var i=0; i<scorekeysArray.length; i++) {
			if (!(scorekeysArray[i] in starInfoObj)) {
				flag = false;
				break;
			}
		}
		if(flag){
			var starinfo = '';
			for(key in starInfoObj) {
				if(starinfo == ''){
					starinfo = key + ":" + starInfoObj[key];
				}else{
					starinfo += ","+ key + ":" + starInfoObj[key];
				}
			}
			ajax.send('$baseurl&step=score&hid=$hid&starinfo='+ starinfo,'',function(){
					showDialog("success","评分成功！",2);
					setTimeout("window.location.reload();",1000);
				}
			);
		}
	}catch(e){
	}
}
setOnclickEvent();
function clickStar2(){
	showDialog("warning","24小时内不能重复评分",5);
	return false;
}
</script>
<!--
EOT;
?>-->